home *** CD-ROM | disk | FTP | other *** search
/ The Best of MacTutor - S…e Code for Volumes 1 to 5 / The Best of MacTutor - Source Code for Volume 1-5 (Wayzata Technology)(6031)(1990).bin / Source Code / #21 (Jun 87) / format source / FormatEqu.a < prev    next >
Text File  |  1987-05-07  |  3KB  |  86 lines

  1. ;***************** File FormatEqu.a ****************************
  2. ;***************************************************************
  3. ;
  4. ; A list of equates used in the SCSI formatting program.
  5.  
  6. ; Menu Bar resource numbers
  7.  
  8. AppleM        EQU        128
  9. FileM        EQU        129
  10. EditM        EQU        130
  11. SCSIM        EQU        131
  12.  
  13. ; Dialog box resource numbers
  14. AboutRN        EQU        128
  15. SelAddrRN    EQU        129
  16. ParamRN        EQU        130
  17. EDefectsRN    EQU        131
  18. AboutItem        EQU        1
  19.  
  20. DialWLen    EQU        170            ;lenght of window storage for
  21.                                     ;dialog box
  22.  
  23. ; Event Processing Equates
  24.  
  25. AllEvents    EQU        $0000FFFF
  26. EventMask    EQU        $FFFF
  27.  
  28. ; Codes used in error dialog box for SCSI Manager traps.
  29. Reset         EQU        $A0
  30. Get             EQU        $A1
  31. Select         EQU        $A2
  32. Command         EQU        $A3
  33. Complete    EQU        $A4
  34. Read         EQU        $A5
  35. Write         EQU        $A6
  36. Install         EQU        $A7
  37. Stat         EQU        $A10
  38.  
  39. ; Codes used in error dialog box for SCSI commands.
  40. RezeroUnit    EQU        1
  41. TestUReady    EQU        0
  42. FormatUnit    EQU        4
  43. ModeSelect    EQU        $15
  44.  
  45. MaxTicks    EQU        108000        ;max number of ticks to wait for
  46.                                     ;a SCSI command to complete
  47. MaxAddr        EQU        6            ;largest SCSI address
  48. MaxCylind    EQU        2048        ;largest number of cylinders 
  49. MaxHeads    EQU        16            ;largest number of heads 
  50. MaxBFI        EQU        $10000000    ;bigest Bytes From Index value
  51.  
  52. ; Offsets for input buffer used when inputting disk surface 
  53. ; defect information (relative to the beginning of that record).
  54. CylBBuff    EQU    0            ;offset for cylinder field
  55. HeadBBuff    EQU    4            ;offset for head field
  56. BFIBBuff    EQU    8            ;offset for bytes from index field
  57.  
  58. ; Offset for each record in output buffer (relative
  59. ; to the beginning of that record).
  60. CylOut        EQU        0            ;Offset for cylinder 
  61. HeadOut        EQU        3            ;Offset for head 
  62. BFIOut        EQU        4            ;Offset for byte from index
  63.  
  64. ; Equates for buffer sizes.  Note there are two buffers for 
  65. ; defects, one for input, and another reformated one for output
  66. ; during the Format Unit command.
  67. MaxBBs        EQU     60            ;Maximum number of defects
  68. BadBRecLen    EQU        16            ;size of each defect record for
  69.                                     ;input buffer
  70. MaxBBListLen    EQU    MaxBBs*BadBRecLen    ;length of defect buffer
  71.                                             ;for input
  72. MaxBBOutLen    EQU        (MaxBBs*8)+4    ;length of defect buffer for
  73.                                         ;output during Format
  74.                                         ;Unit command
  75.  
  76. ModeSelBytesOut        EQU    22        ;bytes transfered in Mode Select
  77.                                     ;command
  78.  
  79. ParamBuffLen    EQU        30        ;length of SCSI command
  80.                                     ;parameter buffer
  81. CBuffLen        EQU        10        ;length of command buffer
  82. StrBuffLen        EQU        256        ;length of string buffers
  83. CommLenS        EQU        6        ;lenght of class 0 commands
  84. CommLenL        EQU        10        ;length of class 1 commands
  85. PProgLen        EQU        30        ;Pseudo program buffer length
  86.